package com.project.sianet.entidades;

import org.codehaus.jackson.annotate.JsonIgnoreProperties;
import org.codehaus.jackson.annotate.JsonProperty;

import android.os.Parcel;
import android.os.Parcelable;

@JsonIgnoreProperties(ignoreUnknown=true)
public class Alumno extends Usuario {

	public String grado;
	
	public Alumno() {
		super();
	}

	public Alumno(String login, String contrasenia, String nombres, String apePaterno, String apeMaterno, String grado) {
    	super(login, contrasenia, nombres, apePaterno, apeMaterno);
    	this.grado = grado;
	}

	@JsonProperty("Seccion")
	public String getGrado() {
		return grado;
	}

	@JsonProperty("Seccion")
	public void setGrado(String grado) {
		this.grado = grado;
	}

	@Override
	public int describeContents() {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public void writeToParcel(Parcel out, int flags) {
		super.writeToParcel(out, flags);
		out.writeString(grado);
	}
	
	public static final Parcelable.Creator<Alumno> CREATOR = new Parcelable.Creator<Alumno>() {
		public Alumno createFromParcel(Parcel in) {
		    return new Alumno(in);
		}
		
		public Alumno[] newArray(int size) {
		    return new Alumno[size];
		}
	};
	
	private Alumno(Parcel in) {
		super(in);
		grado = in.readString();
    }
	
}
